<%@ page language="java" import="java.util.*" pageEncoding="UTF-8" %>
<%@taglib prefix="s" uri="/struts-tags" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
    <base href="<%=basePath%>">
    <title>信息管理</title>
	
    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="cache-control" content="no-cache">
    <meta http-equiv="expires" content="0">
    <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
    
    <link href="back/css/main.css" rel="stylesheet" type="text/css" />
	<script type="text/javascript" src="gko100/back/admin/js/onclick.js"></script>
	<style type="text/css">
	<!--
	body {
		margin-left: 0px;
		margin-top: 0px;
		margin-right: 0px;
		margin-bottom: 0px;
	}
	.STYLE1 {font-size: 12px}
	.STYLE3 {font-size: 12px; font-weight: bold; }
	.STYLE4 {
		color: #03515d;
		font-size: 12px;
	}
	-->
	</style>
	<script type="text/javascript">

			/**
			 * 选中所有的复选框
			 * @param ids 复选框的name属性
			 * @param type 按钮类型
			 */
			function checkAllBtn(ids, id) {
				try {
					var t = $("#" +id);
					if(t.val() == "全选中") {
						$("[name="+ids+"]:checkbox").each(function() { 
							$(this).attr("checked", "true"); 
						}) 
						t.val("全不选");
					} else {
						$("[name="+ids+"]:checkbox").each(function() { 
							$(this).removeAttr("checked"); 
						})
						t.val("全选中");
					}
					return false;
				}catch(e) {
				}
			}
				
			
		</script>
	
</head>

<body>
	<div align="center">
	    <form method="post" id="articleForm" name="articleForm">
			<table width="100%" border="0" align="center" cellpadding="2" cellspacing="1" bordercolor="#59D6FF" class="table">
				<tr>
					<td height="35" colspan="10" bgcolor="#FFFFFF" class="td_bg">
						&nbsp;
						<img src="back/images/list.gif" />
						<a href="arti_insert.action" title="添加文章" style="font-size: 13px; color: #428EFF;">&nbsp;<strong>新增文章</strong>
						</a>
						<a href="#" onClick="javascript:window.location.reload();return false;" title="刷新当前列表" style="font-size: 13px; color: #428EFF;">
							&nbsp;<strong>刷新页面</strong>
						</a>
						<a href="artiListDel_find.action?pageNo=1&nav.navId=<s:property value='#avl.navId' />" title="查看回收站信息">
							&nbsp;<strong>查看回收站</strong>
						</a>
						<!-- 
							<a>&nbsp;&nbsp;&nbsp;&nbsp;
								<input id="keyword" name="keyword" style="width: 175px;" />&nbsp;
								<img id="keywordbtn" style="cursor: pointer;" title="点击查询" src="back/images/search.gif" />
							</a>
							&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
							<select name="selectedNavId" id="classId">
								<option value="-1" style="color: #42619B">查看所有</option>
								<s:iterator value="" id="">
									<option value="220">About</option>
									<option value="248">&nbsp;&nbsp;├&nbsp;Introduction</option>
									<option value="247">&nbsp;&nbsp;├&nbsp;Program</option>
									<option value="246">&nbsp;&nbsp;├&nbsp;Culture</option>
									<option value="245">&nbsp;&nbsp;└&nbsp;Goal</option>
								</s:iterator>
								
							</select>
						 -->
						
					</td>
				</tr>
				<tr>
					<td width="80" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						全选
					</td>
					<td width="300" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						文章标题
					</td>
					<td width="70" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						排序值
					</td>
					<td width="70" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						浏览次数
					</td>
					<td width="60" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						文章作者
					</td>
					<td width="65" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						添加时间
					</td>
					<td width="38" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						审核
					</td>
					<td width="46" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						热门
					</td>
					<td width="80" align="center" bgcolor="#FFFFFF" class="bg_tr" style="font-size: 13px;">
						操作选项
					</td>
				</tr>
				<s:iterator value="artiVoList" id="avl">
					<tr>
					
						<td width="29" align="center" class="td_bg">
							<input type="checkbox" name="ids" value="760" />
						</td>
	
						<td align="left" class="td_bg">
							[ <s:property value="#avl.navTitle" /> ]&nbsp;&nbsp;
							<!-- 
								<a style="color: #FF0000;" href="javascript:void()" onClick="javascript:return commend(760);">推荐</a>
							 -->
							
							<a style="color: " href="artiByArtiId_find.action?arti.artiId=<s:property value='#avl.artiId' />" title="<s:property value='#avl.artiTitle' />">
								<s:property value='#avl.artiTitle' />
							 </a>
						</td>
						
						<td align="center" class="td_bg">
							<input onBlur="javascript:return modifyOrderValue(760)" alt="0" type="text" 
								style="width: 50px; text-align: center; border: thin;" id="b760" value="<s:property value='#avl.priority' />" />
						</td>
						<td align="center" class="td_bg">
							<input id="hits0" onmouseout="setHits(760, this.value, this.id)"
								onclick="initHits();" style="width: 30px; text-align: center;"
								value="<s:property value='#avl.clickNums' />" />次
						</td>
	
						<td align="center" class="td_bg">
							<s:property value='#avl.author' />
						</td>
	
						<td align="center" class="td_bg">
							<s:date name="#avl.uploadDate" format="yyyy-MM-dd" />
						</td>
						
						<td align="center" class="td_bg">
							<s:if test="%{#avl.permFlag==1}">
								<a href="#" onClick="javascript:return audit(760);" title="点击禁用文章">
									<img border="0" src="back/images/ysh.gif" />
								</a>
							</s:if>
							<s:elseif test="%{#avl.permFlag==0}">
								<a href="#" onClick="javascript:return audit(760);" title="点击启用文章">
									<img border="0" src="back/images/wsh.gif" />
								</a>
							</s:elseif>
							
						</td>
						<td align="center" class="td_bg">
							<s:if test="%{#avl.hotFlag==1}">
								<a href="#" onClick="javascript:return audit(760);">
									<img border="0" src="back/images/ysh.gif" />
								</a>
							</s:if>
							<s:elseif test="%{#avl.hotFlag==0}">
								<a href="#" onClick="javascript:return audit(760);">
									<img border="0" src="back/images/wsh.gif" />
								</a>
							</s:elseif>
							
						</td>
						<td align="center" class="td_bg">
	
							<a href="arti_upload.action?arti.artiId=<s:property value='#avl.artiId' />" title="点击编辑文章信息">
								<img border="0" src="back/images/edit.gif" />
							</a> &nbsp;&nbsp;
	
							<a href="art_del.action?arti.artiId=<s:property value='#avl.artiId' />" title="点击删除文章信息"
								onclick="if(confirm('是否确认删除该文章信息?')){return true;}else{return false;}">
								<img border="0" src="back/images/remove.gif" />
							</a>
						</td>
					</tr>		
				</s:iterator>

				<tr>
					<td height="40" colspan="10" class="td_bg" style="font-size: 13px;">
						<input value="全选中" type="button" id="all"
							onClick="checkAllBtn('ids','all')" style="cursor: pointer;" />

					</td>

				</tr>

				<tr>
					<td colspan="10" class="td_bg"
						style="font-size: 13px; text-align: center; line-height: 30px;">
						共有<s:property value="artiTotalCount" />条记录 每页显示<s:property value="pageSize" />个记录
						<a href="artiList_find.action?pageNo=1&nav.navId=<s:property value='nav.navId' />" title="跳转到首页">首页</a>
							<s:if test="%{pageNo-1>0}">
							<a href="artiList_find.action?pageNo=<s:property value='pageNo-1' />&nav.navId=<s:property value='nav.navId' />">
						</s:if>
						上一页
						<s:if test="%{pageNo-1>0}">
							</a>
						</s:if>
						<s:iterator id="pn" begin="1" end="5">
							<s:if test="pageNo==#pn">
								<font title="当前在第<s:property value='#pn' />页">[<s:property value='#pn' />]</font>
							</s:if>
							<s:elseif test="%{#pn<pageCount}">
								<a href="imageList_find.action?pageNo=<s:property value='#pn' />">[<s:property value='#pn' />]</a>
							</s:elseif>
						</s:iterator>
						<s:if test="%{pageNo+1<=pageCount}">
							<a href="artiList_find.action?pageNo=<s:property value='pageNo+1' />&nav.navId=<s:property value='nav.navId' />">
						</s:if>
						下一页
						<s:if test="%{pageNo+1<=pageCount}">
						</a>
						</s:if>
						
						<a href="artiList_find.action?pageNo=<s:property value='pageCount' />&nav.navId=<s:property value='nav.navId' />" title="跳转到末页">&nbsp;末页</a>
					</td>
				</tr>
			</table>
		</form>
	</div>
</body>

</html>
